//
//  TimeCell.m
//  Daybook
//
//  Created by dllo on 16/5/21.
//  Copyright © 2016年 zhangbin. All rights reserved.
//

#import "TimeCell.h"
#import "Common.h"
@implementation TimeCell

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        [self createView];

    }
    return self;
}

- (void)createView {
    
    self.timeLabel = [[UILabel alloc]init];
    self.timeLabel.backgroundColor = [UIColor whiteColor];
    [self.contentView addSubview:self.timeLabel];
    
    
    self.pointImageView = [[UIImageView alloc]init];
    self.pointImageView.backgroundColor = [UIColor lightGrayColor];
    [self.contentView addSubview:self.pointImageView];
    
    self.moneyLabel = [[UILabel alloc]init];
    self.moneyLabel.backgroundColor = [UIColor whiteColor];
    [self.contentView addSubview:self.moneyLabel];
    
}


- (void)layoutSubviews {
    self.pointImageView.frame = CGRectMake(MAIN_WIDTH / 2 - 15, 0, 30, 30);
    self.timeLabel.frame = CGRectMake(MAIN_WIDTH / 2  - 15 - 100, 0, 100, 30);
    self.moneyLabel.frame = CGRectMake(MAIN_WIDTH / 2 + 15 + 100, 0, 100, 30);
}


- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
